// 双指针
var reverseList = function(head) {
  let cur = null;
  let pre = head;
  while (pre) {
    let temp = pre.next;
    pre.next = cur;
    cur = pre;
    pre = temp;
  }
  return cur;
};
